<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ taglib prefix="p" uri="/WEB-INF/tld/pagination.tld"%> 
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<meta http-equiv="content-type" content="text/html; charset=UTF-8">
		<title>销售报价管理</title>
		<link rel="stylesheet" type="text/css" href="css/public.css">
		<script language="JavaScript" src="js/public.js"></script>
		<script type="text/javascript" src="js/sorttable.js"></script>
		<script type="text/javascript" src="js/date1.js"></script>
		<script type="text/javascript" src="js/sellprice.js"></script>
		
	</head>
	<body>
	<div id="info_all">
		<div id="info_top">
			销售报价管理
		</div>
		<!-- 主输入区 -->
		<!-- 功能按钮 -->
		<s:form action="getSellPriceByCondition.action" method="post" theme="simple" id="delrow">
		<div id="btn">
			<input type="button" value="新增" onClick="addAction('showAddSellPrice')"
				onFocus="this.blur()" onMouseOver="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="修改" onClick="" onFocus="this.blur()"
				onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="删除"
				onClick="deleteAction('deleteSellPrice')" onFocus="this.blur()"
				onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="下查" onClick="" onFocus="this.blur()"
				onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="审核" onClick="" onFocus="this.blur()"
				onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="反审核" onClick="" onFocus="this.blur()"
				onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="作废" onClick="" onFocus="this.blur()"
				onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="反作废" onClick="" onFocus="this.blur()"
				onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
			<input type="button" value="明细" onClick="showDetail('showSellPriceDetail','销售报价')" 
				onFocus="this.blur()" onmouseover="this.className='btnover'"
				onmouseout="this.className='btnout'" class="btnsize" />
		</div>
		<div id="info_main">
			<!-- 查询栏 -->
			<div id="select">
				<hr>
				<table>
					<tr>
						<td width="60px">
							单据编号
						</td>
						<td width="130px">
							<s:textfield name="sellPrice.sellPriceCode"  size="12" id="sellPriceCode"></s:textfield>
						</td>
	
						<td width="60px">
							购货单位
						</td>
						<td width="130px">	
							<s:hidden name="sellPrice.customerId" id="customerId"></s:hidden>
							<s:textfield  size="12" name="customerName" id="customerName"></s:textfield>
							<img src="images/kookup.gif" style="cursor:hand" onclick="openWin('selectCustomer.action','supplier',750,700,0)">
						</td>
						<td width="60">
							审核状态
						</td>
						<td width="120">
									<s:select list="#{'2':'全部','1':'审核','0':'未审核'}"
											name="sellPrice.checkState" cssStyle="width:100px;">
									</s:select>
						</td>
						<td width="60px">
							报价日期
						</td>
						<td width="130px">
							<s:textfield name="sellPrice.sellDate" id='sellDateFrom' size="12"  cssStyle="cursor:hand" onclick="calendar.setHook(this)"></s:textfield>
						</td>
						<td width="20px">
							到
						</td>
						<td width="130px">
							<s:textfield name="sellPrice.checkDate" id='sellDateTo' size="12"  cssStyle="cursor:hand" onclick="calendar.setHook(this)"></s:textfield>
						</td>
					</tr>
				</table>
			</div>
				<div class="sele">
					<input type="submit" value="查询" onFocus="this.blur()"
						onmouseover="this.className='btnover'"
						onmouseout="this.className='btnout'" id="btnsize" />
					<input type="reset" value="重置" onFocus="this.blur()"
						onmouseover="this.className='btnover'"
						onmouseout="this.className='btnout'" id="btnsize"/>
						<hr>
				</div>
			<!-- 信息显示栏 -->
			<div id="info_info2">
				<table id="info_table" width="850px" cellspacing=1px cellpadding=1px
					class="sortable">
					<thead>
						<tr>
							<th>
								<input type="checkbox" onClick="selectAll()" name="checkbox2" />
							</th>
							<th width="90">
								是否审核
							</th>
							<th width="90">
								单据编号
							</th>
							<th width="100">
								购货单位
							</th>
							<th width="90">
								日期
							</th>
							<th width="90">
								币别
							</th>
							<th width="90">
								汇率
							</th>
							<th width="90">
								主管
							</th>
							<th width="130">
								部门
							</th>
							<th width="90">
								业务员
							</th>
							<th width="90">
								审核人
							</th>
							<th width="90">
								审核日期
							</th>
							<th width="90">
								是否作废
							</th>
						</tr>
					</thead>
					<tbody>
						<s:if test="!sellPriceDTOList.isEmpty">
									<s:iterator value="sellPriceDTOList" status="status">
										<tr>
											<td>
												<s:checkbox name="rowlist"
													fieldValue="%{sellprice.sellPriceId}" theme="simple" 
													value="false" />
											</td>
											<td>
												<s:if test="sellprice.checkState == 0"> 否</s:if>
												<s:elseif test=" sellprice.checkState == 1">是</s:elseif>
											</td>
											<td>
												<s:property value="sellprice.sellPriceCode" />&nbsp;
											</td>
											<td>
												<s:property value="customer.customerName" />&nbsp;
											</td>
											<td>
												<s:property value="sellprice.sellDate" />&nbsp;
											</td>
											<td>
												<s:property value="currency.currencyName" />&nbsp;
											</td>
											<td>
												<s:property value="sellprice.exchangeRate" />&nbsp;
											</td>
											<td>
												<s:property value="manager.candiateName" />&nbsp;
											</td>
											<td>
												<s:property value="department.departmentName" />&nbsp;
											</td>
											<td>
												<s:property value="businesser.candiateName" />&nbsp;
											</td>
											<td>
												<s:property value="sellprice.checker" />&nbsp;
											</td>
											<td>
												<s:property value="sellprice.checkDate" />&nbsp;
											</td>
											<td>
												<s:if test="sellprice.blankOutState == 0"> 否</s:if>
												<s:elseif test=" sellprice.blankOutState == 1">是</s:elseif>
											</td>
										</tr>
									</s:iterator>
						</s:if>

					</tbody>
					<tfoot>
					
					</tfoot>
				</table>
					<div align="center">
							<font color="black"> 共<s:property value="page.total" />
								页 第 <s:property value="page.cpage" /> 页 <p:page
									cpage="%{page.cpage}" total="%{page.total}" url="%{page.url}" />
							</font>

					</div>
				<script language="javascript">  
						//("表格名称","奇数行背景","偶数行背景","点击后背景");
						 mouseclick("info_table","#ffffff","#ffffff","#e6f0fd");
						 //("表格名称","奇数行背景","偶数行背景");
						 //setcolor("t","#ffffff","#ffffff");
					</script>
			</div>
		</div>
		</s:form>
	</div>
	</body>
</html>
